package com.qj.yantaishan.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.beans.factory.annotation.Autowired;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Service;
import com.qj.yantaishan.mapper.AdverCategoryMapper;
import com.qj.yantaishan.domain.AdverCategory;
import com.qj.yantaishan.service.IAdverCategoryService;
import com.qj.yantaishan.common.core.text.Convert;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author qihe
 * @date 2022-07-22
 */
@Service
@Primary
public class AdverCategoryServiceImpl    extends ServiceImpl<AdverCategoryMapper, AdverCategory>  implements IAdverCategoryService
{
    @Autowired
    private AdverCategoryMapper adverCategoryMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param catId 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public AdverCategory selectAdverCategoryByCatId(Long catId)
    {
        return adverCategoryMapper.selectAdverCategoryByCatId(catId);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param adverCategory 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<AdverCategory> selectAdverCategoryList(AdverCategory adverCategory)
    {
        return adverCategoryMapper.selectAdverCategoryList(adverCategory);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param adverCategory 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertAdverCategory(AdverCategory adverCategory)
    {
        return adverCategoryMapper.insertAdverCategory(adverCategory);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param adverCategory 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateAdverCategory(AdverCategory adverCategory)
    {
        return adverCategoryMapper.updateAdverCategory(adverCategory);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param catIds 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteAdverCategoryByCatIds(String catIds)
    {
        return adverCategoryMapper.deleteAdverCategoryByCatIds(Convert.toStrArray(catIds));
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param catId 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteAdverCategoryByCatId(Long catId)
    {
        return adverCategoryMapper.deleteAdverCategoryByCatId(catId);
    }
}
